import {BasicColumn} from '/@/components/Table';
import {FormSchema} from '/@/components/Table';
import { rules} from '/@/utils/helper/validator';
import { render } from '/@/utils/common/renderUtils';
//列表数据
export const columns: BasicColumn[] = [
];

//查询数据
export const searchFormSchema: FormSchema[] = [
];

//表单数据
export const formSchema: FormSchema[] = [
  {
    label: '网站名',
    field: 'name',
    component: 'Input',
    dynamicRules: ({model,schema}) => {
      return [
              { required: true, message: '请输入网站名!'},
             ];
    },
  },
  {
    label: '网站域名',
    field: 'domain',
    component: 'Input',
    dynamicRules: ({model,schema}) => {
      return [
              { required: true, message: '请输入网站域名!'},
             ];
    },
  },
  {
    label: 'SEO关键词',
    field: 'keyword',
    component: 'Input',
    dynamicRules: ({model,schema}) => {
      return [
              { required: true, message: '请输入SEO关键词!'},
             ];
    },
  },
  {
    label: '网站描述',
    field: 'description',
    component: 'Input',
    dynamicRules: ({model,schema}) => {
      return [
              { required: true, message: '请输入网站描述!'},
             ];
    },
  },
  {
    label: '站长QQ',
    field: 'qq',
    component: 'Input',
    dynamicRules: ({model,schema}) => {
      return [
              { required: true, message: '请输入站长QQ!'},
             ];
    },
  },
  {
    label: '网站logo图片（默认）',
    field: 'logo',
    component: 'Input',
    dynamicRules: ({model,schema}) => {
      return [
              { required: true, message: '请输入网站logo图片（默认）!'},
             ];
    },
  },
  {
    label: '网站logo图片（深色）',
    field: 'logoDark',
    component: 'Input',
    dynamicRules: ({model,schema}) => {
      return [
              { required: true, message: '请输入网站logo图片（深色）!'},
             ];
    },
  },
	// TODO 主键隐藏字段，目前写死为ID
  {
    label: '',
    field: 'id',
    component: 'Input',
    show: false,
  },
];
